home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 43 / Amiga Format CD43 (1999)(Future Publishing)(GB)(Track 1 of 2)[!][issue 1999-09].iso / -serious- / graphics / photofolio1_0 / photofolio093 / install-photofolio next >
Text File  |  1999-06-15  |  14KB  |  337 lines

  1. ; Install PhotoFolio
  2. ; $VER: Install-PhotoFolio V1.0 (2.3.99)
  3. ; © 1999 Steve Quartly and Paul Huxham
  4.  
  5. (set #catalog 1) ; english language is default
  6.  
  7. ; Find the current language
  8. (set #i 0)
  9. (while (set #thisfile (select #i
  10.         "italiano" "deutsch" "español" "català" "dansk" "français"
  11.         "hrvatski" "nederlands" "norsk" "polski" "português"
  12.         "russian" "srpski" "suomi" "Svenska" "ÃeÓtina"
  13.   ""))
  14.   (
  15.     (if (= @language #thisfile) (set #catalog #i))
  16.     (set #i (+ #i 1))
  17.   )
  18. )
  19.  
  20. ; Query user for their language, using system as default
  21. (set #catalog
  22.   (askchoice
  23.     (prompt "Select your native language")
  24.     (help @askoptions-help)
  25.     (choices
  26.         "" "English" "Italiano" "Deutsch" "Español")
  27.     (default #catalog)
  28.   )
  29. )
  30.  
  31. ; Some string defaults common for all languages
  32. (set #HOMEPAGE "http://mafeking.scouts.org.au/~paulh/photofolio.html")
  33. (set #BLANK "\n")
  34.  
  35. ; ************************** English texts ******************************
  36. (set #INITIAL_MESSAGE
  37.   (cat "\nWelcome to the PhotoFolio installer\n\n\n"
  38.     "You can obtain free updates to PhotoFolio\n"
  39.     "at the PhotoFolio homepage\n\n"
  40.     #HOMEPAGE
  41.     "\n\n\nThe authors, Steve Quartly and Paul Huxham\n"
  42.     "would like to thank you for using PhotoFolio")
  43. )
  44. (set #WRONG_INSTALLER_VERSION "\n\n\n\nYou need at least version 42.9 of Installer\nto install PhotoFolio")
  45. (set #WRONG_OS_VERSION "\n\n\n\nYou need AmigaOS V3.0\nto run PhotoFolio")
  46. (set #WRONG_MUI_VERSION "\n\n\n\nYou need MUI 3.8\nto run PhotoFolio")
  47. (set #WRONG_LISTTREE_VERSION "\n\n\n\nYou need Listtree.mcc 17.53\nto run PhotoFolio")
  48. (set #WRONG_NLIST_VERSION "\n\n\n\nYou need NList.mcc 19.90\nto run PhotoFolio")
  49. (set #WRONG_NLISTVIEW_VERSION "\n\n\n\nYou need NListview.mcc 19.90\nto run PhotoFolio")
  50. (set #YOU_NEED_GUIGFX "\n\nTo run PhotoFolio on an ECS, AGA or other non-CyberGraphX system,\n\nyou need to obtain render.library and guigfx.library from Aminet\n\nand install them before running PhotoFolio")
  51. (set #CONTINUE_INSTALLATION "Continue PhotoFolio installation")
  52. (set #STOP_INSTALLATION "Don't install PhotoFolio now")
  53. (set #SELECT_INSTALL_DIRECTORY "Select a directory to install PhotoFolio into.\n(If you want PhotoFolio in its own directory - create one now)")
  54. (set #INSTALLING_PROGRAM "\n\n\n\nInstalling PhotoFolio program")
  55. (set #PROMPT_SET_TOOLTYPE "\n\n\nSet PhotoFolio graphics mode tooltype?\n(guigfx or cybergraphics, determined automatically)")
  56. (set #PROMPT_INSTALL_DOCS "\n\n\n\nInstall PhotoFolio documentation?\n\n(Amigaguide)")
  57. (set #INSTALLING_DOCS "\n\n\n\nInstalling PhotoFolio documentation")
  58. (set #BETTER_PROCESSOR "\n\n\nYou should obtain versions of jpeg.library and proof.library\n\noptimised for your CPU from\n\n")
  59. (set #INSTALL_68020_VERSIONS "Versions for the 68020 CPU will now be installed")
  60. (set #INSTALLING_LIBRARIES "Installing required PhotoFolio libraries\n\n")
  61. (set #PROMPT_SET_PREFS "\n\n\n\nSet up proof.library preferences in ENVARC: and ENV:?")
  62. (set #UPDATES_AVAILABLE "\n\nUpdates of PhotoFolio and its required libraries\n\nare available from the PhotoFolio home page")
  63. (set #YES "Yes")
  64. (set #NO "No")
  65. (set #WHICH_LANGUAGES  "\n\n\n\nWhat language catalogs would you like to install?")
  66.  
  67. ; ************************** Italian texts ******************************
  68. (if (= #catalog 2)
  69. (
  70. (set #INITIAL_MESSAGE
  71.   (cat "\nBenvenuto all'installazione di PhotoFolio\n\n\n"
  72.    "Puoi ottenere gli aggiornamenti gratuiti di PhotoFolio\n"
  73.    "alla homepage di PhotoFolio\n\n"
  74.    #HOMEPAGE
  75.    "\n\n\nGli autori, Steve Quartly e Paul Huxham\n"
  76.    "desiderano ringraziarti per aver scelto PhotoFolio")
  77. )
  78. (set #WRONG_INSTALLER_VERSION "\n\n\n\nNecessiti almeno della versione 42.9 dell'Installer\nper installare PhotoFolio")
  79. (set #WRONG_OS_VERSION "\n\n\n\nNecessiti di AmigaOS 3.x\nper lanciare PhotoFolio")
  80. (set #WRONG_MUI_VERSION "\n\n\n\nNecessiti di  MUI 3.8\nper lanciare PhotoFolio")
  81. (set #WRONG_LISTTREE_VERSION "\n\n\n\nNecessiti di Listtree.mcc 17.53\nper lanciare PhotoFolio")
  82. (set #WRONG_NLIST_VERSION "\n\n\n\nNecessiti di NList.mcc 19.90\nper lanciare PhotoFolio")
  83. (set #WRONG_NLISTVIEW_VERSION "\n\n\n\nNecessiti di NListview.mcc 19.90\nper lanciare PhotoFolio")
  84. (set #YOU_NEED_GUIGFX "\n\nPer lanciare PhotoFolio su un sistema ECS, AGA o un altro non CyberGraphX,\n\nhai bisogno delle render.library e guigfx.library da Aminet\n\ne devi installarle prima di lanciare PhotoFolio")
  85. (set #CONTINUE_INSTALLATION "Continua l'installazione di PhotoFolio")
  86. (set #STOP_INSTALLATION "Non installare ora PhotoFolio")
  87. (set #SELECT_INSTALL_DIRECTORY "Scegli un cassetto in cui installare PhotoFolio.\n(Se vuoi PhotoFolio in un suo cassetto - creane uno adesso)")
  88. (set #INSTALLING_PROGRAM "\n\n\n\nInstallazione del programma PhotoFolio")
  89. (set #PROMPT_SET_TOOLTYPE "\n\n\nImposto la modalità grafica di PhotoFolio via tooltype?\n(guigfx o cybergraphics, determinato automaticamente)")
  90. (set #PROMPT_INSTALL_DOCS "\n\n\n\nInstallo la documentazione di  PhotoFolio?\n\n(Amigaguide)")
  91. (set #INSTALLING_DOCS "\n\n\n\nInstallazione della documentazione di PhotoFolio")
  92. (set #BETTER_PROCESSOR "\n\n\nPuoi ottenere versioni ottimizzate della jpeg.library\n\ne proof.library per la tua CPU da\n\n")
  93. (set #INSTALL_68020_VERSIONS "Ora verranno installate le versioni per la CPU 68020")
  94. (set #INSTALLING_LIBRARIES "Installazione delle librerie richieste da PhotoFolio\n\n")
  95. (set #PROMPT_SET_PREFS "\n\n\n\nImposto le preferenze per la proof.library in ENVARC: e ENV:?")
  96. (set #UPDATES_AVAILABLE "\n\nAggiornamenti di PhotoFolio e delle sue librerie\n\nsono disponibili alla homepage di PhotoFolio")
  97. (set #YES "Sì")
  98. (set #NO "No")
  99. (set #WHICH_LANGUAGES  "\n\n\n\nPer quale lingua vuoi installare i cataloghi?")
  100. )
  101. )
  102.  
  103. ; ************************** German texts ******************************
  104. (if (= #catalog 3)
  105. (
  106. (set #INITIAL_MESSAGE
  107.   (cat "\nWillkommen zur PhotoFolio Installation\n\n\n"
  108.     "Sie können die jeweils neueste Programm Version von\n"
  109.     "der PhotoFolio Homepage herunterladen\n\n"
  110.     #HOMEPAGE
  111.     "\n\n\nDie Autoren, Steve Quartly und Paul Huxham,\n"
  112.     "danken Ihnen, daß Sie PhotoFolio benutzen.")
  113. )
  114. (set #WRONG_INSTALLER_VERSION "\n\n\n\nSie benötigen mindestens Version 42.9 des Installers\num PhotoFolio installieren zu können")
  115. (set #WRONG_OS_VERSION "\n\n\n\nSie benötigen AmigaOS V3.0\num PhotoFolio zu starten")
  116. (set #WRONG_MUI_VERSION "\n\n\n\nSie benötigen MUI 3.8\num PhotoFolio starten zu können")
  117. (set #WRONG_LISTTREE_VERSION "\n\n\n\nSie benötigen Listtree.mcc 17.53\num PhotoFolio starten zu können")
  118. (set #WRONG_NLIST_VERSION "\n\n\n\nSie benötigen NList.mcc 19.90\num PhotoFolio starten zu können")
  119. (set #WRONG_NLISTVIEW_VERSION "\n\n\n\nSie benötigen NListview.mcc 19.90\num PhotoFolio starten zu können")
  120. (set #YOU_NEED_GUIGFX "\n\nUm PhotoFolio auf ECS-, AGA- oder anderen nicht-CyberGraphX Systemen\n\nstarten zu können, benötigen Sie render.library und guigfx.library (Aminet),\n\ndie vor dem Start von PhotoFolio installiert sein müssen")
  121. (set #CONTINUE_INSTALLATION "PhotoFolio Installation fortsetzen")
  122. (set #STOP_INSTALLATION "PhotoFolio nicht installieren")
  123. (set #SELECT_INSTALL_DIRECTORY "Wählen Sie ein Verzeichnis, in das Sie PhotoFolio installieren wollen.\n(Wenn Sie ein eigenes Verzeichnis für PhotoFolio wünschen,\ndann müssen Sie es JETZT erstellen)")
  124. (set #INSTALLING_PROGRAM "\n\n\n\nInstalliere PhotoFolio Programm")
  125. (set #PROMPT_SET_TOOLTYPE "\n\n\nTooltype für PhotoFolio Grafikmodus setzen?\n(guigfx oder cybergraphics, automatisch ermittelt)")
  126. (set #PROMPT_INSTALL_DOCS "\n\n\n\nPhotoFolio Dokumentation installieren?\n\n(Amigaguide)")
  127. (set #INSTALLING_DOCS "\n\n\n\nInstalliere PhotoFolio Dokumentation")
  128. (set #BETTER_PROCESSOR "\n\n\nSie sollten für Ihren Prozessor optimierte Versionen der\n\nproof.library und der jpeg.library herunterladen:\n\n")
  129. (set #INSTALL_68020_VERSIONS "68020-optimierte Versionen werden nun installiert")
  130. (set #INSTALLING_LIBRARIES "Installiere benötigte PhotoFolio Libraries\n\n")
  131. (set #PROMPT_SET_PREFS "\n\n\n\nproof.library Einstellungen in ENVARC: und ENV: erstellen?")
  132. (set #UPDATES_AVAILABLE "\n\nNeue Versionen von PhotoFolio und den benötigten Libraries\n\nsind auf der PhotoFolio Homepage erhältlich")
  133. (set #YES "Ja")
  134. (set #NO "Nein")
  135. (set #WHICH_LANGUAGES  "\n\n\n\nWelche Sprache möchten Sie installieren?")
  136. )
  137. )
  138.  
  139. ; ************************** Spanish texts ******************************
  140. (if (= #catalog 4)
  141. (
  142. (set #INITIAL_MESSAGE
  143.   (cat "\nBienvenido al Instalador de Photofolion\n\n"
  144.     "Podrás obtener actualizaciones gratuitas\n"
  145.     "en la página web de PhotoFolio\n\n"
  146.     #HOMEPAGE
  147.     "\n\n\nLos autores, Steve Quartly y Paul Huxham\n"
  148.     "desean dar las gracias a los usuarios de PhotoFolio")
  149. )
  150. (set #WRONG_INSTALLER_VERSION "\n\n\n\nNecesitas al menos la versión 42.9 del Installer\npara instalar PhotoFolio")
  151. (set #WRONG_OS_VERSION "\n\n\n\nNecesitas el AmigaOS V3.0\npara ejecutar PhotoFolio")
  152. (set #WRONG_MUI_VERSION "\n\n\n\nNecesitas MUI 3.8\npara usar PhotoFolio")
  153. (set #WRONG_LISTTREE_VERSION "\n\n\n\nNecesitas la Listtree.mcc 17.53\npara arrancar PhotoFolio")
  154. (set #WRONG_NLIST_VERSION "\n\n\n\nNecesitas la NList.mcc 19.90\npara ejecutar PhotoFolio")
  155. (set #WRONG_NLISTVIEW_VERSION "\n\n\n\nNecesitas la  NListview.mcc 19.90\npara usar PhotoFolio")
  156. (set #YOU_NEED_GUIGFX "\n\nPara ejecutar PhotoFolio en un sistema ECS, AGA u otro sin CyberGraphX,\n\nnecesitas bajarte las render.library y guigfx.library de Aminet\n\ne instalarlas antes de ejecutar PhotoFolio")
  157. (set #CONTINUE_INSTALLATION "¿Continuar la instalación de PhotoFolio")
  158. (set #STOP_INSTALLATION "No quiero instalar PhotoFolio ahora")
  159. (set #SELECT_INSTALL_DIRECTORY "Selecciona un directorio donde instalar PhotoFolio.\n(Si quieres PhotoFolio en su propio cajón - crea uno ahora)")
  160. (set #INSTALLING_PROGRAM "\n\n\n\nInstalando el programa PhotoFolio")
  161. (set #PROMPT_SET_TOOLTYPE "\n\n\n¿Ajusto las tooltypes para el modo gráfico de PhotoFolio?\n(guigfx o cybergraphics, determinado automáticamente)")
  162. (set #PROMPT_INSTALL_DOCS "\n\n\n\n¿Instalo la documentación de PhotoFolio?\n\n(Amigaguide)")
  163. (set #INSTALLING_DOCS "\n\n\n\nInstalando documentación de PhotoFolio")
  164. (set #BETTER_PROCESSOR "\n\n\nDeberías obtener versiones de jpeg.library y proof.library\n\noptimizadas para tu CPU\n\n")
  165. (set #INSTALL_68020_VERSIONS "Ahora se instalarán versiones para la procesadores 68020")
  166. (set #INSTALLING_LIBRARIES "Instalando librerías necesarias para PhotoFolio\n\n")
  167. (set #PROMPT_SET_PREFS "\n\n\n\n¿Guardo las preferencias de la proof.library en ENVARC: y ENV:?")
  168. (set #UPDATES_AVAILABLE "\n\nLas actualizaciones de PhotoFolio y librerías necesarias\n\nestán a tu disposición en la página web de PhotoFolio")
  169. (set #YES "Yes")
  170. (set #NO "No")
  171. (set #WHICH_LANGUAGES  "\n\n\n\n¿Qué catálogos deseas instalar?")
  172. )
  173. )
  174.  
  175. ; ************************* Global procedures ***************************
  176. (procedure P_copylib lib path
  177.   (
  178.     (set #libr (cat lib ".library"))
  179.     (copylib (prompt (cat #INSTALLING_LIBRARIES #libr))
  180.       (help @copylib-help)
  181.       (source (cat path #libr))
  182.       (dest "LIBS:")
  183.       (confirm expert)
  184.     )
  185.   )
  186. )
  187.  
  188. ; *********************** PhotoFolio install ****************************
  189. (if (< @installer-version (+ (* 65536 42) 9))
  190.     (abort #WRONG_INSTALLER_VERSION)
  191. )
  192.  
  193. (set os_version (/ (getversion "intuition.library" (resident)) 65536))
  194. (if (< os_version 39)
  195.     (abort #WRONG_OS_VERSION)
  196. )
  197.  
  198. (set mui_version (getversion "MUI:Libs/muimaster.library" ))
  199. (if (AND (< mui_version 1245219) (<> mui_version 0 ))
  200.     (abort #WRONG_MUI_VERSION)
  201. )
  202.  
  203. (set listtree_version (getversion "MUI:Libs/mui/Listtree.mcc" ))
  204. (if (AND (< listtree_version 1114165) (<> listtree_version 0 ))
  205.     (abort #WRONG_LISTTREE_VERSION)
  206. )
  207.  
  208. (set nlist_version (getversion "MUI:Libs/mui/NList.mcc" ))
  209. (if (AND (< nlist_version 1245246) (<> nlist_version 0 ))
  210.     (abort #WRONG_NLIST_VERSION)
  211. )
  212.  
  213. (set nlistview_version (getversion "MUI:Libs/mui/NListview.mcc" ))
  214. (if (AND (< nlistview_version 1245246) (<> nlistview_version 0 ))
  215.     (abort #WRONG_NLISTVIEW_VERSION)
  216. )
  217.  
  218. ; All essential version numbers are correct, continue installation
  219. (message #INITIAL_MESSAGE)
  220.  
  221. (set cgfx_version (/ (getversion "cybergraphics.library" (resident)) 65536))
  222. (if (= cgfx_version "")
  223.     (
  224.         (set continue
  225.             (askbool
  226.                 (prompt #YOU_NEED_GUIGFX)
  227.                 (help @askbool-help)
  228.                 (choices #STOP_INSTALLATION #CONTINUE_INSTALLATION)
  229.                 (default 1)
  230.             )
  231.         )
  232.  
  233.         (if (= continue 1)
  234.             (exit (quiet))
  235.         )
  236.  
  237.         (set ttv_guigfx "YES")
  238.     )
  239.     (
  240.         (set ttv_guigfx "NO")
  241.     )
  242. )
  243.  
  244. ; Set destination directory for install
  245. (set destination
  246.     (askdir
  247.         (prompt #SELECT_INSTALL_DIRECTORY)
  248.         (help @askdir-help)
  249.         (default @default-dest)
  250.     )
  251. )
  252.  
  253. (set @default-dest destination)
  254.  
  255. ; Install executable and icon
  256. (copyfiles
  257.     (prompt #INSTALLING_PROGRAM)
  258.     (source "")
  259.     (choices "PhotoFolio" "PhotoFolio.info")
  260.     (dest @default-dest)
  261.     (files)
  262.     (optional askuser)
  263. )
  264.  
  265. ; Set the tooltypes
  266. (tooltype
  267.     (prompt #PROMPT_SET_TOOLTYPE)
  268.     (help @tooltype-help)
  269.     (dest (tackon @default-dest "PhotoFolio"))
  270.     (settooltype "GUIGFX" ttv_guigfx)
  271.     (noposition)
  272. )
  273.  
  274. ; Install documentation
  275. (set install_docs
  276.     (askbool
  277.         (prompt #PROMPT_INSTALL_DOCS)
  278.         (help @askbool-help)
  279.         (choices #YES #NO)
  280.         (default 1)
  281.     )
  282. )
  283.  
  284. (if (= install_docs 1)
  285.     (copyfiles
  286.         (prompt #INSTALLING_DOCS)
  287.         (source "")
  288.         (choices "PhotoFolio.guide" "PhotoFolio.guide.info")
  289.         (dest @default-dest)
  290.         (files)
  291.         (optional askuser)
  292.     )
  293. )
  294.  
  295. ; Remind user of beeter libraries for their cpu
  296. (if (> (database "cpu") 68020 )
  297.     (message (cat #BETTER_PROCESSOR #HOMEPAGE #BLANK #BLANK #BLANK #INSTALL_68020_VERSIONS))
  298. )
  299.  
  300. ; Install required libraries
  301. (set #i 0)
  302. (while (set #thislib (select #i "proof" "image" "jpeg" ""))
  303.     (
  304.         (if (<> #thislib "")
  305.             (P_copylib #thislib "Libs/")
  306.         )
  307.         (set #i (+ #i 1))
  308.     )
  309. )
  310.  
  311. ; Set up prefs in envarc
  312. (if (not (exists "ENVARC:proof.library"))
  313.     (makedir "ENVARC:proof.library")
  314. )
  315.  
  316. (textfile
  317.     (prompt #PROMPT_SET_PREFS)
  318.     (help @textfile-help)
  319.     (dest "ENVARC:proof.library/Test_Proof_By_Protection")
  320.     (append "no\n")
  321. )
  322.  
  323. ; Set up prefs in env
  324. (if (not (exists "ENV:proof.library"))
  325.     (makedir "ENV:proof.library")
  326. )
  327.  
  328. (textfile
  329.     (prompt #PROMPT_SET_PREFS)
  330.     (help @textfile-help)
  331.     (dest "ENV:proof.library/Test_Proof_By_Protection")
  332.     (append "no\n")
  333. )
  334.  
  335. ; Finished installation
  336. (message (cat #UPDATES_AVAILABLE #BLANK #BLANK #HOMEPAGE))
  337.